package pres.lnk.learn.designpattern.o_command.command;

import pres.lnk.learn.designpattern.o_command.receiver.Receiver;

/**
 * 关闭电器命令
 * @Author lnk
 * @Date 2018/4/13
 */
public class OffCommand implements Command {
    private Receiver receiver;

    public OffCommand(Receiver receiver) {
        this.receiver = receiver;
    }

    @Override
    public void execute() {
        receiver.off();
    }
}
